import {request} from "./request";

//1.搜索分页营销管理数据
export function getMarclientPageInfo({pageNum,pageSize,customerName, createMan, state , devResult}){
    return request({
        url: '/mar/salechance/pager',
        method: 'get',
        params:{
            pageNum,
            pageSize,
            customerName,
            createMan,
            state,
            devResult
        }
    })
}

//2.搜索分页客户开发计划管理数据
export function getMarPlanPageInfo({pageNum,pageSize}){
    return request({
        url: '/cusDevPlan/pager',
        method: 'get',
        params:{
            pageNum,
            pageSize,
        }
    })
}
//添加计划项
export function addPlan(cusDevPlan){
    return request({
        url:'/cusDevPlan/add',
        method:'post',
        data:cusDevPlan
    })
}
/* 开发成功 */
export function succeedSaleChance(id){
    return request({
        url: '/cusDevPlan/' + id,
        method: 'put',
        date:id
    })
}
/*开发失败*/
export function failSaleChance(id){
    return request({
        url: '/cusDevPlan/sb/' + id,
        method: 'put',
        date:id
    })
}
/*执行成功*/
export function execute(id){
    return request({
        url: '/cusDevPlan/zx/' + id,
        method: 'put',
        date:id
    })
}
/*执行失败*/
export function executeFail(id){
    return request({
        url: '/cusDevPlan/execute/' + id,
        method: 'put',
        date:id
    })
}
